import { request, requestToken } from '@/utils/request';
import axios from 'axios'
/**
 * 登录模块
 * @param {*} params 
 * @returns 
 */
// 登录接口 
export const login = (params) => { return request("post", "/hkfrich-api/system/hkfrich/login", params) };

// 获取验证码 
export const getAuthCodeImg = (params) => { return "/hkfrich-api/system/hkfrich/getAuthCodeImg?userName=" + params + "&timestamp=" + new Date().getTime() };
// 获取用户菜单
export const getRouter = (params) => { return request("post", "/hkfrich-api/system/hkfrich/getRouter", params) };
// 退出接口
export const logout = () => { return requestToken("post", "/hkfrich-api/system/hkfrich/logout") };



/**
 * 
 * @returns 用户模块
 */
// 列表接口
export const listUser = (params) => { return requestToken("post", "/hkfrich-api/system/user/list",params) };
export const getUser = (params) => { return requestToken("post", "/hkfrich-api/system/user/getUser",params) };
export const addUser = (params) => { return requestToken("post", "/hkfrich-api/system/user/save",params) };
export const updateUser = (params) => { return requestToken("post", "/hkfrich-api/system/user/updateById",params) };
export const delUser = (params) => { return requestToken("post", "/hkfrich-api/system/user/removeByIds",params) };
export const changeUserStatus = (params) => { return requestToken("post", "/hkfrich-api/system/user/changeUserStatus",params) };
export const resetUserPwd = (params) => { return requestToken("post", "/hkfrich-api/system/user/resetUserPwd",params) };